<!--  -->
<template>
  <div class="dialog">
    <div class="title">2.接种人管理</div>
    <div class="tip">请您务必填写真实的接种者信息,以便能够顺利接种!</div>
    <ValidationObserver
      ref="observer"
      v-slot="{ passes, invalid }"
      tag="form"
      @submit.prevent="submit()"
    >
      <van-cell-group>
        <ValidationProvider name="姓名" rules="required|isName" v-slot="{ errors }">
          <van-field
            v-model="form.name"
            placeholder="请输入姓名"
            label="姓名"
            clearable
            :error-message="errors[0]"
          />
        </ValidationProvider>

        <calendar/>

        <ValidationProvider name="联系方式" rules="required|isPhone" v-slot="{ errors }">
          <van-field
            v-model="form.phone"
            placeholder="请输入联系方式"
            label="联系方式"
            clearable
            :error-message="errors[0]"
          />
        </ValidationProvider>
      </van-cell-group>
    </ValidationObserver>
  </div>
</template>

<script>
import { ValidationObserver, ValidationProvider, extend } from "vee-validate";
import Calendar from "@/components/calendar";

export default {
  components: { ValidationObserver, ValidationProvider, Calendar },
  data() {
    return {
      form: {}
    };
  },
  //方法集合
  methods: {},
  created() {},
  //生命周期 - 挂载完成（可以访问DOM元素）
  mounted() {}
};
</script>
<style lang='scss' scoped>

</style>